package com.code.day14;


import java.util.Arrays;

public class Day14Arrays {
    public static void main(String[] args) {
        int[] arr = {1, 2, 3, 4, 5};
        System.out.println(Arrays.toString( arr));

        int[] arr2 ={5,4,3,2,1};
        System.out.println(Arrays.toString(arr2));

        int[] arr3 = {1,2,3,4,5,6,7,8,9,10};
        int index = Arrays.binarySearch(arr3, 5);
        System.out.println(index);

        int[] arr4 ={1,2,3,4,5};
        int[] newArr = Arrays.copyOf(arr4, 10);
        arr4 = newArr;
        System.out.println(Arrays.toString(arr4));
    }
}
